package com.os.serviceimpl;

import java.util.List;

import com.os.dao.StoreDaoH;
import com.os.daoimpl.StoreDaoImplH;
import com.os.model.StoreH;
import com.os.service.OverloadStoreServiceH;
/**
 * 重载库存服务实现类
 * @author HQG 2017年1月4日
 *
 */
public class OverloadStoreServiceImplH implements OverloadStoreServiceH{

	StoreDaoH sdao = new StoreDaoImplH();
	
	@Override
	public int overloadStoreH() {
		int flag = 0;
		int a = sdao.deleteStoreAllH();
		List<StoreH> foods = sdao.getAllFoodsH();
		boolean b = sdao.setStoresH(foods);
		if(a != 0 && b){
			flag = 1;
		}
		return flag;
	}

}
